/*
 * XML Type:  AccountRequest
 * Namespace: http://ofx.net/types/2003/04
 * Java type: net.ofx.types.x2003.x04.AccountRequest
 *
 * Automatically generated - do not modify.
 */
package net.ofx.types.x2003.x04.impl;
/**
 * An XML AccountRequest(@http://ofx.net/types/2003/04).
 *
 * This is a complex type.
 */
public class AccountRequestImpl extends org.apache.xmlbeans.impl.values.XmlComplexContentImpl implements net.ofx.types.x2003.x04.AccountRequest
{
    
    public AccountRequestImpl(org.apache.xmlbeans.SchemaType sType)
    {
        super(sType);
    }
    
    private static final javax.xml.namespace.QName SVCADD$0 = 
        new javax.xml.namespace.QName("", "SVCADD");
    private static final javax.xml.namespace.QName SVCCHG$2 = 
        new javax.xml.namespace.QName("", "SVCCHG");
    private static final javax.xml.namespace.QName SVCDEL$4 = 
        new javax.xml.namespace.QName("", "SVCDEL");
    private static final javax.xml.namespace.QName SVC$6 = 
        new javax.xml.namespace.QName("", "SVC");
    
    
    /**
     * Gets the "SVCADD" element
     */
    public net.ofx.types.x2003.x04.ServiceAdd getSVCADD()
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.ServiceAdd target = null;
            target = (net.ofx.types.x2003.x04.ServiceAdd)get_store().find_element_user(SVCADD$0, 0);
            if (target == null)
            {
                return null;
            }
            return target;
        }
    }
    
    /**
     * True if has "SVCADD" element
     */
    public boolean isSetSVCADD()
    {
        synchronized (monitor())
        {
            check_orphaned();
            return get_store().count_elements(SVCADD$0) != 0;
        }
    }
    
    /**
     * Sets the "SVCADD" element
     */
    public void setSVCADD(net.ofx.types.x2003.x04.ServiceAdd svcadd)
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.ServiceAdd target = null;
            target = (net.ofx.types.x2003.x04.ServiceAdd)get_store().find_element_user(SVCADD$0, 0);
            if (target == null)
            {
                target = (net.ofx.types.x2003.x04.ServiceAdd)get_store().add_element_user(SVCADD$0);
            }
            target.set(svcadd);
        }
    }
    
    /**
     * Appends and returns a new empty "SVCADD" element
     */
    public net.ofx.types.x2003.x04.ServiceAdd addNewSVCADD()
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.ServiceAdd target = null;
            target = (net.ofx.types.x2003.x04.ServiceAdd)get_store().add_element_user(SVCADD$0);
            return target;
        }
    }
    
    /**
     * Unsets the "SVCADD" element
     */
    public void unsetSVCADD()
    {
        synchronized (monitor())
        {
            check_orphaned();
            get_store().remove_element(SVCADD$0, 0);
        }
    }
    
    /**
     * Gets the "SVCCHG" element
     */
    public net.ofx.types.x2003.x04.ServiceChange getSVCCHG()
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.ServiceChange target = null;
            target = (net.ofx.types.x2003.x04.ServiceChange)get_store().find_element_user(SVCCHG$2, 0);
            if (target == null)
            {
                return null;
            }
            return target;
        }
    }
    
    /**
     * True if has "SVCCHG" element
     */
    public boolean isSetSVCCHG()
    {
        synchronized (monitor())
        {
            check_orphaned();
            return get_store().count_elements(SVCCHG$2) != 0;
        }
    }
    
    /**
     * Sets the "SVCCHG" element
     */
    public void setSVCCHG(net.ofx.types.x2003.x04.ServiceChange svcchg)
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.ServiceChange target = null;
            target = (net.ofx.types.x2003.x04.ServiceChange)get_store().find_element_user(SVCCHG$2, 0);
            if (target == null)
            {
                target = (net.ofx.types.x2003.x04.ServiceChange)get_store().add_element_user(SVCCHG$2);
            }
            target.set(svcchg);
        }
    }
    
    /**
     * Appends and returns a new empty "SVCCHG" element
     */
    public net.ofx.types.x2003.x04.ServiceChange addNewSVCCHG()
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.ServiceChange target = null;
            target = (net.ofx.types.x2003.x04.ServiceChange)get_store().add_element_user(SVCCHG$2);
            return target;
        }
    }
    
    /**
     * Unsets the "SVCCHG" element
     */
    public void unsetSVCCHG()
    {
        synchronized (monitor())
        {
            check_orphaned();
            get_store().remove_element(SVCCHG$2, 0);
        }
    }
    
    /**
     * Gets the "SVCDEL" element
     */
    public net.ofx.types.x2003.x04.ServiceDelete getSVCDEL()
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.ServiceDelete target = null;
            target = (net.ofx.types.x2003.x04.ServiceDelete)get_store().find_element_user(SVCDEL$4, 0);
            if (target == null)
            {
                return null;
            }
            return target;
        }
    }
    
    /**
     * True if has "SVCDEL" element
     */
    public boolean isSetSVCDEL()
    {
        synchronized (monitor())
        {
            check_orphaned();
            return get_store().count_elements(SVCDEL$4) != 0;
        }
    }
    
    /**
     * Sets the "SVCDEL" element
     */
    public void setSVCDEL(net.ofx.types.x2003.x04.ServiceDelete svcdel)
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.ServiceDelete target = null;
            target = (net.ofx.types.x2003.x04.ServiceDelete)get_store().find_element_user(SVCDEL$4, 0);
            if (target == null)
            {
                target = (net.ofx.types.x2003.x04.ServiceDelete)get_store().add_element_user(SVCDEL$4);
            }
            target.set(svcdel);
        }
    }
    
    /**
     * Appends and returns a new empty "SVCDEL" element
     */
    public net.ofx.types.x2003.x04.ServiceDelete addNewSVCDEL()
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.ServiceDelete target = null;
            target = (net.ofx.types.x2003.x04.ServiceDelete)get_store().add_element_user(SVCDEL$4);
            return target;
        }
    }
    
    /**
     * Unsets the "SVCDEL" element
     */
    public void unsetSVCDEL()
    {
        synchronized (monitor())
        {
            check_orphaned();
            get_store().remove_element(SVCDEL$4, 0);
        }
    }
    
    /**
     * Gets the "SVC" element
     */
    public net.ofx.types.x2003.x04.ServiceEnum.Enum getSVC()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_element_user(SVC$6, 0);
            if (target == null)
            {
                return null;
            }
            return (net.ofx.types.x2003.x04.ServiceEnum.Enum)target.getEnumValue();
        }
    }
    
    /**
     * Gets (as xml) the "SVC" element
     */
    public net.ofx.types.x2003.x04.ServiceEnum xgetSVC()
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.ServiceEnum target = null;
            target = (net.ofx.types.x2003.x04.ServiceEnum)get_store().find_element_user(SVC$6, 0);
            return target;
        }
    }
    
    /**
     * Sets the "SVC" element
     */
    public void setSVC(net.ofx.types.x2003.x04.ServiceEnum.Enum svc)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_element_user(SVC$6, 0);
            if (target == null)
            {
                target = (org.apache.xmlbeans.SimpleValue)get_store().add_element_user(SVC$6);
            }
            target.setEnumValue(svc);
        }
    }
    
    /**
     * Sets (as xml) the "SVC" element
     */
    public void xsetSVC(net.ofx.types.x2003.x04.ServiceEnum svc)
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.ServiceEnum target = null;
            target = (net.ofx.types.x2003.x04.ServiceEnum)get_store().find_element_user(SVC$6, 0);
            if (target == null)
            {
                target = (net.ofx.types.x2003.x04.ServiceEnum)get_store().add_element_user(SVC$6);
            }
            target.set(svc);
        }
    }
}
